package com.rightsidetech.system.dtos.request;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;

@Data
public class RuleCommoditySpecsSaveReq implements Serializable {


    @ApiModelProperty(value = "规格条码",required = true)
    @NotBlank(message = "规格条码不允许为空")
    private String barCode;

    @ApiModelProperty(value = "商品规格")
    private String specs;

    @ApiModelProperty(value = "规则积分",required = true)
    @NotNull(message = "规则积分不可为空")
    @Range(min = 0,message = "规则积分不可为负数")
    private BigDecimal ruleValue;
}
